import java.util.Scanner;
public class Task10 {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int x = sc.nextInt();
		int counter = 0;
		if (x < 0){
			counter++;
		}
		while (x != 0){
			x = sc.nextInt();
			if(x < 0)
				counter++;
		}
		
		System.out.println(counter);
		sc.close();

	}

}
